import { IFeidaoAiMobile } from '@dfeidao/atom-mobile/interfaces';

/**
 * 设置存储
 * @param fd 固定参数
 * @param key 键
 * @param val 值
 * @see [api](https://dfeidao.gitee.io/feidao-web/browser/local)
 * @example
 * ```ts
 * import set from '@dfeidao/atom-mobile/local/set';
 * set(fd, 'key', val);
 * ```
 */

export default function set(fd: IFeidaoAiMobile, key: string, val: unknown) {
	const local = fd.local as { [key: string]: unknown; };
	local[key] = val;
}
